import request from '@/utils/request'

// 查询土特产产品列表
export function listProducts(query) {
  return request({
    url: '/assisting/products/list',
    method: 'get',
    params: query
  })
}

// 查询土特产产品详细
export function getProducts(productsId) {
  return request({
    url: '/assisting/products/' + productsId,
    method: 'get'
  })
}

// 新增土特产产品
export function addProducts(data) {
  return request({
    url: '/assisting/products',
    method: 'post',
    data: data
  })
}

// 修改土特产产品
export function updateProducts(data) {
  return request({
    url: '/assisting/products',
    method: 'put',
    data: data
  })
}

// 删除土特产产品
export function delProducts(productsId) {
  return request({
    url: '/assisting/products/' + productsId,
    method: 'delete'
  })
}

// 查询土特产产品列表（无权限）
export function selectAllList(query) {
  return request({
    url: '/assisting/products/selectAllList',
    method: 'get',
    params: query
  })
}
